home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 967 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.3 KB

  1. Path: mail2news.demon.co.uk!genesis.demon.co.uk
  2. From: Lawrence Kirby <fred@genesis.demon.co.uk>
  3. Newsgroups: comp.lang.c
  4. Subject: Re: memory allocation in Visual C++
  5. Date: Wed, 10 Jan 96 14:48:03 GMT
  6. Organization: none
  7. Message-ID: <821285283snz@genesis.demon.co.uk>
  8. References: <4cvds8$4pt@news.ust.hk>
  9. Reply-To: fred@genesis.demon.co.uk
  10. X-NNTP-Posting-Host: genesis.demon.co.uk
  11. X-Newsreader: Demon Internet Simple News v1.27
  12. X-Mail2News-Path: genesis.demon.co.uk
  13.  
  14. In article <4cvds8$4pt@news.ust.hk> ee_ckmaa@uxmail.ust.hk "Chan Ka Ming" writes:
  15.  
  16. >I'm writting a program which deals with a large amount of data. It's a 
  17. >16 bit program. Why I cannot allocate automatic arrays in a
  18. >function as local variables which in total occupies more than 64k? I've set the
  19. >memory model to "large" , though.
  20.  
  21. You may be limited by the overall stack size available to the program.
  22. Try a DOS/Windows newsgroup to discuss what limitations your particular
  23. compiler imposes.
  24.  
  25. Why do you need the arrays to be automatic? You'd probably be better off
  26. making them static or allocating them from the heap (the c.l.c FAQ has a
  27. good section on allocating '2D' arrays).
  28.  
  29. -- 
  30. -----------------------------------------
  31. Lawrence Kirby | fred@genesis.demon.co.uk
  32. Wilts, England | 70734.126@compuserve.com
  33. -----------------------------------------
  34.